<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<%@ page isELIgnored="false" %>
<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<title>用户列表</title>
		<%--<link rel="stylesheet" type="text/css" href="css/common.css">
		<link rel="stylesheet" type="text/css" href="css/yetong.css">--%>
		<script type="text/javascript">
			function searchUser(){
				//alert("dd");
				$("#mainForm").submit();
			}
		</script>
		<style>
			.table-c table{border-right:1px solid #F00;border-bottom:1px solid #F00}
			.table-c table td{border-left:1px solid #F00;border-top:1px solid #F00}
			/* css注释：只对table td标签设置红色边框样式 */
		</style>
	</head>
	<body>
		<div id="main">
			<aside id="left_list" class="lf">
				<ul>
					<li><a href="../user/findUser.do">用户列表</a></li>
					<li><a href="../order/findOrderList.do">订单列表</a></li>
				</ul>
			</aside>
            <div id="main_content">
				<div>
					<form id="mainForm" name="mainForm" action="../user/findUser.do" method="post">
						<div><h5>用户名称：</h5><input id="userName" name="userName" type="text" <c:if test="${user.userName!=null}">value="${user.userName}" </c:if>/></div>
						<div><h5>用户电话：</h5><input id="userTel" name="userTel" type="text" <c:if test="${user.userTel!=null}">value="${user.userTel}" </c:if>/></div>
						<div><h5>用户地址：</h5><input id="userAddress" name="userAddress" type="text" <c:if test="${user.userAddress!=null}">value="${user.userAddress}" </c:if>/></div>
						<div><input type="submit" value="搜索"/></div>
					</form>

				</div>
				<div id="result" class="table-c">
					<table width="100%"  border="0" cellspacing="0" cellpadding="0">
						<tr>
							<th>用户IP</th>
							<th>用户姓名</th>
							<th>电话</th>
							<th>地址</th>
							<th>创建时间</th>
							<th>登录时间</th>
						</tr>
						<c:forEach items="${userList}" var="user">
						<tr>
							<td>${user.userId}</td>
							<td>${user.userName}</td>
							<td>${user.userTel}</td>
							<td>${user.userAddress}</td>
							<td><fmt:formatDate value="${user.userCreatedate}" pattern="yyyy-MM-dd HH:mm:ss"></fmt:formatDate></td>
							<td><fmt:formatDate value="${user.userLogindate}" pattern="yyyy-MM-dd HH:mm:ss"></fmt:formatDate></td>
						</tr>
						</c:forEach>
					</table>
					<%--<a href="/user/findUser.do?page=1">首页</a><a href=""></a><a href=""></a><a href=""></a><a href="/user/findUser.do?page=${}">尾页</a>--%>



				</div>
			</div>
			
			
		</div>
	</body>
</html>
